package acm.浙大新生赛;

import java.util.LinkedList;
import java.util.Scanner;

public class D {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int T = sc.nextInt();
        while (T-- > 0) {
            int r = sc.nextInt();
            int l=1;
            LinkedList<Integer> list=new LinkedList<>();
            if (r%2==0) {
                while (r>=l){
                    list.addFirst(r--);
                    if (l>r){
                        break;
                    }
                    list.addFirst(l++);
                }
            }else {
                while (r>=l){
                    list.addFirst(l++);
                    if (l>r){
                        break;
                    }
                    list.addFirst(r--);
                }
            }
            list.forEach(o->{
                System.out.printf(o+" ");
            });
            System.out.println();
        }
    }
}
